<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8" />
		<link href="__THEMES__/style/frame.css" rel="stylesheet" />
		<script src="__JS__/jQuery/jquery.js" type="text/javascript"></script>
		<include file="Public:js_artDialog" />
		<script type="text/javascript">
			$(function(){
				setWindowSize();
				$(window).resize(setWindowSize);
				$('.menu_1_list').click(function(){
					var url = $(this).attr('href');
					$.ajax({
						url : url,
						type : 'GET',
						cache : false,
						dataType : 'html',
						success : function(e){
							$('.menu_2').html(e);
						}
					});
					return false;
				});
				$('.menu_2_list').live('click',function(){
					$('.menu_2_list').parent().removeClass('this');
					$(this).parent().addClass('this');
				});
				$('.menu_2 li').live({
					mouseover : function(){
						$(this).css("background","#ffffff");
					},
					mouseout : function(){
						$(this).removeAttr('style');
					}
				});
			});
			
			function alertClose(){
				$('#alertbox').slideUp();
			}
			
			function setWindowSize(){
				var doc_height = $(window).height();
				var top_height = 50;
				var fot_height = 50;
				var bod_height = doc_height - ( top_height + fot_height );
				$('#body').height( bod_height - 15 ).width( $(window).width() );
				$('#sidebar').height( bod_height - 15 );
				$('#sidebar .menu_2').height( bod_height - 15 );
				$('#frame').height( bod_height - 15 ).width( $(window).width() - ( $('#sidebar').width() + 15 ) );
			}
		</script>
		<title>{:C('ADMIN_TITLE')}</title>
	</head>
	<body>
		<div id="top">
			<a href="__APP__" class="logo"></a>
			<ul class="top_menu">
    			<li>Welcome to {:C('ADMIN_TITLE')}</li>
    			<li><a href="#">快捷菜单</a></li>
    			<li><a href="#">清理缓存</a></li>
    			<li><a href="{:U('public/logout')}">安全退出</a></li>
    		</ul>
		</div>
		<div id="body">
			<div id="sidebar">
				<ul class="menu_1">
					<li class="this" rel="home" id="menu_home"><a href="__APP__"></a></li>
					<?php
			            $top_menu_list = unique_arr($_SESSION['au_menu_list']);
			            foreach($top_menu_list as $keys=>$vals){
			                if ($vals['pid'] == 0){
			        ?>
			        <li rel="{$vals['id']}"><a href="{:U('index/getmenu',array('ID'=>$vals["id"]))}" rel="{$vals['id']}" class="menu_1_list" id="menu_{$vals['name']}">{//$vals['title']}</a></li>
			        <?php
			                }
			            }
			        ?>
				</ul>
				<div class="menu_2">
					<h2 class="list_menu_title">自定义菜单</h2>
					<ul>
						<li><span></span><a href="javascript:void(0);" class="menu_2_list" target="main">自定义菜单壹</a></li>
						<li><span></span><a href="javascript:void(0);" class="menu_2_list" target="main">自定义菜单贰</a></li>
						<li><span></span><a href="javascript:void(0);" class="menu_2_list" target="main">自定义菜单叁</a></li>
						<li><span></span><a href="javascript:void(0);" class="menu_2_list" target="main">自定义菜单肆</a></li>
					</ul>
					<div class="fo_top"></div>
					<div class="fo_bottom"></div>
				</div>
			</div>
			<div id="frame"><iframe src="{:U('index/main')}" id="main" name="main" width="100%" height="100%" frameborder="0" scrolling="yes" style="overflow: visible;display:"></iframe></div>
		</div>
		<div id="footer">{:C('FOOTER_COPY')}</div>
	</body>
</html>